import { Component, OnInit } from '@angular/core';
import { Clone } from '../../utils/clone'

@Component({
  selector: 'app-home',
  templateUrl: './home.component.html',
  styleUrls: ['./home.component.scss']
})
export class HomeComponent implements OnInit {
  constructor( private clone: Clone) { }
  target = {
    field1: 1,
    field2: undefined,
    field3: {
      child: 'child'
    },
    field4: [2, 4, 8],
  }
  
  ngOnInit(): void {
    // this.target.target
    console.time()
    let data = this.clone.deepClone(this.target)
    console.timeEnd()
  }

}

